﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="BillingDailyInvList.aspx.cs" EnableEventValidation="false" Inherits="WMS6.Web.Billing.BillingDailyInvList" culture="auto" meta:resourcekey="PageResource1" uiculture="auto" %>
<%@ PreviousPageType VirtualPath="~/Billing/BillingDailyInvQuery.aspx" %>
<%@ Register Src="../UserControls/Pager.ascx" TagName="Pager" TagPrefix="uc1" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>BillingOrderList</title>
    <link href="../style/zh/1/css.css" type="text/css" rel="Stylesheet" id="mycss" />
    <link href="../Css/style.css" type="text/css" rel="stylesheet" />

    <script src="../Js/jquery.js" type="text/javascript"></script>

    <script src="../Js/jquery.simplemodal.js" type="text/javascript"></script>

    <script src="../Js/util.js" id="js" type="text/javascript"></script>

    <script src="../Js/InitPage.js" type="text/javascript"></script>

    <script src="../Js/checkbox.js" type="text/javascript"></script>
    
    <script src="../Js/jquery.blockUI.js" type="text/javascript"></script>

    <base target="_self" />

    <script type="text/javascript">
        //初始化页面
        window.onload = function(){
            var action = document.getElementById("hdnActionID").value;
            if(action != null && action != "")
            {
                var array = action.split(',');
                initQueryPage(array[0],array[1]);
            }
            else
            {
                initListPage();
            }
        }
        
        //锁屏
		function blockScreen()
		{
		    //锁屏
		    $.blockUI.defaults.message = GetBlockUIMsg();
            $.blockUI.defaults.overlayCSS.backgroundColor = GetBlockUIBgColor();
            $.blockUI();
        }
        
        function returnSearch()
        {
            var from = document.getElementById("hdnFrom").value;
            if(from != "")
            {
                window.location.href = "BillingDailyInvQuery.aspx";
            }
            else
            {
                window.history.go(-1);
            }
        }       
    </script>

</head>
<body>
    <form id="F9231" runat="server">
    <div>
        <asp:ScriptManager ID="ScriptManager1" runat="server" />
        <div id="div_List_top">
            <table>
                <tr>
                    <td valign="bottom">
                        <asp:Label ID="lblBillingOrderList" runat="server" CssClass="label_header" Text="仓储费列表" meta:resourcekey="lblBillingOrderList"></asp:Label>
                    </td>
                    <td>
                        <asp:Button ID="btnRun" runat="server" CssClass="button" Enabled="False" Text="运行"
                         OnClientClick="blockScreen();" 
                          OnClick="btnRun_Click" meta:resourcekey="btnRunResource1" />
                    </td>
                    <td><asp:Button ID="btnAction" runat="server" CssClass="button" Enabled="False" 
                            Text="<%$ Resources:ButtonResource,btnAction %>" 
                            meta:resourcekey="btnActionResource1" /></td>
                </tr>
            </table>
        </div>
        <div class="blank8">
        </div>
        <asp:UpdatePanel ID="up1" runat="server">
            <ContentTemplate>
                <div id="div_List">
                <div id="div_List_msg">
                        <asp:Label ID="lblMsg" runat="server" CssClass="label_message" 
                            meta:resourcekey="lblMsgResource1"></asp:Label>
                    </div>
                    <asp:GridView ID="gvBillingDailyInv" runat="server" AutoGenerateColumns="False" PageSize="50" oninit="gvBillingDailyInv_Init" 
                        CssClass="gridview" DataKeyNames="OWNER_ID,DAYS,IS_BILLING_CREDENCE,IS_STATEMENT" OnRowDataBound="gvBillingDailyInv_RowDataBound"
                        AllowSorting="True" OnSorting="gvBillingDailyInv_Sorting" OnSelectedIndexChanging="gvBillingDailyInv_SelectedIndexChanging"
                        meta:resourcekey="gvBillingDailyInv">
                        <FooterStyle CssClass="GridViewFooterStyle" />
                        <RowStyle CssClass="GridViewRowStyle" />
                        <HeaderStyle CssClass="GridViewHeaderStyle" />
                        <AlternatingRowStyle CssClass="GridViewAlternatingRowStyle" />
                        <Columns>
                            <asp:BoundField HeaderText="序号" FooterText="序号" meta:resourcekey="No">
                                <ItemStyle CssClass="GridViewRowWidth_40" />
                            </asp:BoundField>
                            <asp:TemplateField meta:resourcekey="TemplateField">
                                <HeaderTemplate>
                                    <asp:CheckBox ID="CheckBox1" runat="server" onclick="selectAll(this,'gvBillingDailyInv');" meta:resourcekey="CheckBox1" />
                                </HeaderTemplate>
                                <ItemTemplate>
                                    <asp:CheckBox ID="chbSelect" runat="server" meta:resourcekey="chbSelect" />
                                </ItemTemplate>
                                <FooterTemplate>
                                    <asp:CheckBox ID="CheckBox2" runat="server" onclick="selectAll(this,'gvBillingDailyInv');" meta:resourcekey="CheckBox2" />
                                </FooterTemplate>
                                <HeaderStyle HorizontalAlign="Center" CssClass="GridViewRowWidth_40" />
                                <ItemStyle HorizontalAlign="Center" CssClass="GridViewRowWidth_40" />
                            </asp:TemplateField>

                            <asp:BoundField DataField="OWNER_ID" HeaderText="货主代码" FooterText="货主代码" SortExpression="OWNER_ID" 
                                meta:resourcekey="OWNER_ID">
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:BoundField>
                            
                            <asp:TemplateField HeaderText="日期" FooterText="日期" 
                                SortExpression="DAYS" meta:resourcekey="DAYS">
                                <ItemTemplate>
                                    <asp:HyperLink ID="HyperLink1" runat="server" Text='<%# Eval("DAYS") %>' NavigateUrl='<%# FormatUrl("~/Billing/BillingDailyInvDetail.aspx?from=list&ID={0}&OwnerID={1}",Eval("DAYS").ToString(),Eval("OWNER_ID").ToString()) %>'
                                        Target="_self" CssClass="hyperlink" meta:resourcekey="HyperLink1Resource1"></asp:HyperLink>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:TemplateField>
                            
                            <asp:BoundField DataField="IS_BILLING_CREDENCE" HeaderText="生成凭证" FooterText="生成凭证" SortExpression="IS_BILLING_CREDENCE"
                                meta:resourcekey="IS_BILLING_CREDENCE">
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:BoundField>
                            
                            <asp:BoundField DataField="IS_STATEMENT" HeaderText="是否对账" FooterText="是否对账" SortExpression="IS_STATEMENT"
                                meta:resourcekey="IS_STATEMENT">
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:BoundField>
                        </Columns>
                    </asp:GridView>
                </div>
                <div id="div_pager">
                    <uc1:Pager ID="PagerFooter" runat="server" OnFirst="btnFirst_Click" OnPrevious="btnPrevious_Click"
                        OnNext="btnNext_Click" OnLast="btnLast_Click" OnGoTo="GoTo_Click" />
                </div>
            </ContentTemplate>
            <Triggers>
                <asp:AsyncPostBackTrigger ControlID="btnRun" EventName="Click" />
                <%--<asp:AsyncPostBackTrigger ControlID="btnList" EventName="Click" />--%>
            </Triggers>
        </asp:UpdatePanel>
        <div id="div_List_bottom">
            <table>
                <tr>
                    <td>
                        <asp:Button ID="btnNewSearch" runat="server" Text="<%$ Resources:ButtonResource,btnNewSearch %>"
                            Enabled="False" CssClass="button" OnClick="btnNewSearch_Click" 
                            meta:resourcekey="btnNewSearchResource1" />
                    </td>
                    <td>
                        <asp:Button ID="btnReSearch" runat="server" Text="<%$ Resources:ButtonResource,btnReSearch %>"
                            Enabled="False" CssClass="button" 
                            OnClientClick="javascript:returnSearch();return false;" 
                            meta:resourcekey="btnReSearchResource1" />
                    </td>
                    <%--<td>
                        <asp:Button ID="btnList" runat="server" Text="<%$Resources:ButtonResource,btnList%>"
                            Enabled="False" CssClass="button" OnClick="btnList_Click" />
                    </td>--%>
                    <td>
                        <asp:Button ID="btnExport" runat="server" Text="<%$ Resources:ButtonResource,btnExport %>"
                            Enabled="False" CssClass="button" OnClick="btnExport_Click" 
                            meta:resourcekey="btnExportResource1" />
                    </td>
                </tr>
            </table>
        </div>
    </div>
    <input type="hidden" id="hiddenFlag" />
    <input type="hidden" id="hdnFrom" runat="server" />
    <input type="hidden" id="hdnActionID" runat="server" />
    <input type="hidden" id="hdnRtnValue" runat="server" />
    <input type="hidden" id="hdnOwnerID" runat="server" />
    </form>
</body>
</html>

